﻿@model yq.IBase.Table.TableInfo
@{
    Layout = null;
}
using System;
using System.ComponentModel; 

namespace yq.Enums.@(Model.ClassName)
{
@foreach (var info in Model.Columns.Where(obj=>obj.Stereotype=="enum"))
{
   <text>
    /// <summary>
    /// @info.Name
    /// </summary>
    public enum @info.Code
    {
     @foreach(var enumString in info.Comment.Replace("\r\n", "￥").Split(char.Parse("￥")))
     {
               if (enumString == "")
               {
                   break;
               }
           var enuminfo = enumString.Split(char.Parse(" ")).Where(obj=>!string.IsNullOrEmpty(obj)).ToArray();
        <text>
        
        [Description("@(enuminfo[1])")] 
        @enuminfo[2] = @enuminfo[0],
            </text>
           }
    
       [Description("默认")] 
        Default=-1
    }
     </text>
}


} 